﻿using System;
using Eamon.MeituanDotnetSDK.api.common;
using Eamon.MeituanDotnetSDK.api.oauth.entity;
using Eamon.MeituanDotnetSDK.@enum;

namespace Eamon.MeituanDotnetSDK.api.oauth
{
    public class DynamicToken : AbstractAPI<TokenResponse>
    {
        public DynamicToken(DynamicTokenRequest request)
        {
            this.apiRequest = request;
        }

        public override String getHttpUrl()
        {
            return "https://api-open-cater.meituan.com/oauth/token";
        }

        public override Type getRequestClass()
        {
            return typeof(DynamicTokenRequest);
        }

        public override String getMethod()
        {
            return "oauth.token";
        }
    }
}
